import request from '@/utils/request'

export function add(data) {
  return request({
    url: '/ss/sys/organizationUnit/add',
    method: 'post',
    data: data
  })
}

export function list(tenantId) {
  return request({
    url: '/ss/sys/organizationUnit/list',
    method: 'get',
    params: {tenantId}
  })
}

export function deleteOrganizationUnit(id) {
  return request({
    url: '/ss/sys/organizationUnit/delete',
    method: 'get',
    params: {id}
  })
}


export function organizationUnitList(tenantId) {
  return request({
    url: '/ss/sys/organizationUnit/tree',
    mathod: 'get',
    params: {tenantId: tenantId}
  })
}
